package com.iflytek.day20;

public class _04_IntegerDemo {
  public static void main(String[] args) {
    // String --- int
    String s = "100";
    // 方式1：String --- Integer --- int
    Integer i = Integer.valueOf(s);
    // public int intValue()
    int x = i.intValue();
    System.out.println(x);
    // 方式2
    // public static int parseInt(String s)
    int y = Integer.parseInt(s);
    System.out.println(y);
  }
}
